brainAnat2=ecogVisOnBrainNifti2BrainAnat('MNI.nii',30)
figure
[pH2,cL2]=ecogVisOnBrainRenderBrain(brainAnat2);
elecPos=ecogVisOnBrainExtractElecPosFromMgrid('trans_NLbet_Rigid_grid.mgrid');
elecPos=elecPos(1:64,:);

% the coordinates should aready describe voxel space
[idx2VertexPos2,distancesNeg2]=ecogVisOnBrainFindClosestVertex(brainAnat2,elecPos);
figure %start a new figure for each plot. Lights will add up otherwise
%Render data on a brain surface
smoothPar=[2 10]; %[KernelSize kernelWidth] 
[pH,cL,brainAnat2Pos]=ecogVisOnBrainRenderDataOnBrain(brainAnat2,...    
    brainAnat2.vertices(idx2VertexPos2,[2 1 3]),...    
    ones(length(idx2VertexPos2),1),smoothPar); 

%control lights
set(findobj(gca,'Type','light'),'color',[0.1 0.1 0.1])